import pymysql


class Mysqldate():
    def __init__(self):
        self.get_conn = pymysql.Connect(host="192.168.5.72", user="root", password="123456", port=3306, database='APP')

    def get_cursor(self):
        return self.get_conn.cursor()

    def get_sql_result(self):
        sql = "select * from member"
        get_cursor1 = self.get_cursor()
        get_cursor1.execute(sql)
        get_result = get_cursor1.fetchall()
        return get_result


if __name__ == '__main__':
    m = Mysqldate()
    print(m.get_sql_result())
